<?php

namespace App\Exports;

use App\Models\User;
use Maatwebsite\Excel\Concerns\FromCollection;

class UsersExport implements FromCollection
{
	protected $query;

	/**
	 * UsersExport constructor.
	 * @param $query
	 */
	public function __construct($query)
	{
		$this->query = $query;
	}


	public function collection()
	{
		return $this->query->get();
	}
}
